home *** CD-ROM | disk | FTP | other *** search
- Date: Fri, 25 Jun 93 18:25:29 -0400
- From: "Nicholas S Castellano" <entropy@terminator.rs.itd.umich.edu>
- To: steve@earth.ox.ac.uk
- In-Reply-To: Stephen Usher's message of Fri, 25 Jun 1993 07:57:11 +0100 (BST) <26588.9306250657@earth.ox.ac.uk>
- Subject: nlink_t typedef, which is correct?
-
- >In /usr/include/types.h (mntlib32) nlink_t is typedef'ed to short, whereas
- >in minixfs.h (part of the minix filesystem release 6.0.4) it's typedef'ed to
- >unsigned char.
- >
- >Both of these can't be correct, which one is?
-
- The mint library is correct. nlink_t is defined by POSIX as the type
- of st st_nlink element of struct stat. This element is a short, not a
- char (actually it's supposed to be an unsigned short according to
- mint's file.h...oops...but it's still a word sized element).
-
- Minixfs should use its own type (i suggest mnlink_t in the same way as
- it uses mgid_t for its internal version of a byte-sized gid) instead
- of the POSIX-reserved name nlink_t.
-
- Actually it would be better if minixfs didn't define any names ending
- with _t as these are all reserved in the POSIX namespace. Perhaps
- nlink_mt, gid_mt, and so on would be better for all these internal
- types.
-
- Cheers,
- entropy
-